package com.lizhongbao.system.hystrix;

import com.alibaba.fastjson.JSONObject;
import com.lizhongbao.system.client.BizClient;
import com.lizhongbao.system.domain.dto.TestDto;
import com.lizhongbao.system.domain.dto.TestQueryDto;
import com.lizhongbao.system.domain.eo.Test;
import org.springframework.stereotype.Component;

import javax.validation.Valid;

/**
 * 默认feign服务调用，的熔断器
 *
 * @Author lizhongbao
 * @Date 2019/12/26
 */
@Component
public class BizHystrix implements BizClient {

    @Override
    public JSONObject page(TestQueryDto dto, Long page, Long size) {
        return new JSONObject();
    }

    @Override
    public JSONObject list(TestQueryDto dto) {
        return new JSONObject();
    }

    @Override
    public Test detail(Long id) {
        return new Test();
    }

    @Override
    public Boolean create(@Valid TestDto dto) {
        return false;
    }

    @Override
    public Boolean update(Long id, @Valid TestDto dto) {
        return false;
    }

    @Override
    public Boolean delete(Long id) {
        return false;
    }

    @Override
    public Boolean delete(Long[] ids) {
        return false;
    }
}